<script type="text/javascript">
var feed_limit = 10;
var feedURL = "http://feeds.feedburner.com/feed/comworld";
var animation_duration = 700;
var pause_time = 7000;
var target = "_blank"; // "_top" (same) or "_blank" (new window)

function loadrssfeed() { 
 var options = {
  date: true,
  content: true,
  snippet: false,
  showerror: true,
  errormsg: '',
  key: null

 }; 

 return $(this).each(function(i, e) {
  var $e = $(e);
  
  if (feedURL == null)
   return false;

  var api = "http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&callback=?&q=" + feedURL;
  if (feed_limit != null) api += "&num=" + feed_limit;
  if (options.key != null) api += "&key=" + options.key;

  $.getJSON(api, function(data){ 
   // Check for error
   if (data.responseStatus == 200) {
    // Process the feeds
    _callback(e, data.responseData.feed, options);
   }
  });    
 });
}

function rss_truncate(str, length, suffix) {
    if (str.length <= length) {
        return str;
    }

    if (suffix == undefined) {
        suffix = '...';
    }

    return str.substr(0, length).replace(/\s+?(\S+)?$/g, '') + suffix;
}

// Callback function to create HTML result
var _callback = function(e, feeds, options) {
 if (!feeds) {
  return false;
 }
  
 for (var i=0; i<feeds.entries.length; i++) {
  var entry = feeds.entries[i];
  var html = '<li><a href="'+entry.link+'" target="'+target+'" title="Read this feed at '+ feeds.title +'">'+rss_truncate(entry.title, 70)+'</a></li>';
  $('#feed-content ul').append(html);
 }

    $('#feed-content').vTicker({ showItems: 1, mousePause: true, pause: pause_time, speed: animation_duration});
}

function stoptransition()
{
 if (timer)
 {
  clearTimeout(timer);
  $(':animated', iframe_display).stop(true, true);
 }
  
  autoplay = false;
 timer = null;
}
      
$(document).ready(function() {
 loadrssfeed();
});
</script>